Compiling Multi-Threaded Object-Oriented Programs

نویسندگان

  • Christoph von Praun
  • Thomas R. Gross
چکیده

A compiler must take special care when translating and transforming a multi-threaded program: The presence of synchronization operations and the potential of access conflicts have implications on register allocation and instruction scheduling. Moreover, a compiler might want to inhibit hardware assisted instruction reordering through memory fences, to enable a strong memory model on a platform with weakly ordered memory semantics. Unless the language or user asserts that an input program is free from ’access conflicts’, the compiler must be aware of the concurrency and the data sharing in a program, to guarantee that the output program complies with a certain (well-defined) program semantics. This paper reports on an approach to compile multithreaded object-oriented programs sharing data on a global heap. We developed a whole-program analysis that determines compile-time abstractions for threads and objects. Beyond escape information, the analysis determines the use and update actions of threads to objects and their approximated happens-before ordering. This information is used to implement two variants of sparse instrumentation, addressing the problem of access conflict detection in concurrent programs: (1) Object Race Detection checks if accesses to objects follow a locking discipline at runtime. (2) Object Consistency verifies if threads behave such that accesses to objects happen in a serializable order. Overlapping object accesses, which entail the possibility of data corruption, are detected. Supported, in part, by a grant from Intel Corp., Microprocessor Research Lab (MRL).

برای دانلود رایگان متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

A Verifying Compiler for a Multi-threaded Object-Oriented Language

A verifying compiler automatically verifies the correctness of a source program before compiling it. Founded on the definition of the source language and a set of rules (a methodology) for using the language, the program’s correctness criteria and correctness argument are provided in the program text by interface specifications and invariants. This paper describes the program-verifier component...

متن کامل

Patterns for Reducing Locking Overhead in Multi-threaded Programs

In theory, multi-threading an application can improve performance since multiple instruction streams can be executed simultaneously. In practice, multi-threaded applications often perform no better, or even worse, than single-threaded applications due to the overhead of acquiring and releasing locks [1]. This paper describes several patterns that minimize locking overhead in multi-threaded prog...

متن کامل

Detecting Synchronization Defects in Multi-Threaded Object-Oriented Programs

This dissertation describes an efficient and automated approach to determine synchronization defects in multi-threaded object-oriented programs. The approach is based on the key observation that object-oriented programs provide guarantees about data confinement and encapsulation that can be leveraged by the design of a static analysis and a runtime checker. To be practical, the techniques are d...

متن کامل

Speculative Multithreading: An Object-Driven Approach

Speculative multithreading (SpMT) is a parallelizing execution model for single-threaded programs on multi-core architectures. In this paper, we introduce a new SpMT model, Object-Driven Speculative Multithreading, which exploits the structure and semantics of object-oriented programs to generate speculative parallelism. Within our technique, individual program objects take the responsibility t...

متن کامل

Object{oriented Distributed and Parallel I/o Streams

Writing programs for parallel and distributed computing environments can be signiicantly more complex than writing programs for their sequential counterparts. These complexities mainly arise from the additional synchronization and communication requirements imposed by such environments. These requirements also make debugging and maintaining such programs sig-niicantly more complicated. The prob...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2003